<template>
  <el-menu
    router
    class="el-menu-vertical-demo"
    unique-opened
    :collapse="collapse"
    :collapse-transition="collapse"
    background-color="#304156"
    text-color="#fff"
  >
    <navbar-item :menus="menus" :collapse="collapse"></navbar-item>
  </el-menu>
</template>

<script>
import NavbarItem from './NavbarItem.vue'
export default {
  components: {
    NavbarItem
  },
  props: {
    menus: {
      type: Array,
      require: true,
    },
    collapse: {
      type: Boolean,
      default: false,
    }
  }
}
</script>

<style scoped>
.el-menu {
  height: 100vh;
}
</style>